package cn.firecode.data_collect.utils;

/**
 * @author: yangfan
 * @Date: 2019/12/19
 * @Description:
 */
public enum DcsFileEnum {
    IMG_BEFORE("beforeImg",1), IMG_AFTER("afterImg",2),FORCE_FILE("forceFile",3);

    private String typeName;
    private int index;

    private DcsFileEnum(String _typeName, int _index){
        this.typeName = _typeName;
        this.index = _index;
    }

    public String getTypeName(){
        return this.typeName;
    }

    public int getIndex(){
        return this.index;
    }

    public static DcsFileEnum getEnum(String typeName){
        for(DcsFileEnum en : DcsFileEnum.values()){
            if(en.getTypeName().equals(typeName)){
                return en;
            }
        }
        return null;
    }
}
